package com.hmall.config;

import feign.RequestInterceptor;
import feign.RequestTemplate;
import lombok.extern.slf4j.Slf4j;

/**
 * @author HOLO
 * @create 2023-01-09 3:40
 * @discription
 */

/**
 * 添加Feign的拦截器
 */
@Slf4j
public class MyFeignInterceptor implements RequestInterceptor {

    @Override
    public void apply(RequestTemplate template) {
        template.header("userId", "3");
    }
}
